Hello Tom.
I am building lathe with Kflop+Kstep boards and I have some questions regarding spindle closed loop control setup.
Spindle motor is 220V DC motor. I have designed controller to drive this motor, and it works fine.
DC motor controller drives thyristor bridge, and voltage applied to motor varies depending triac phase firing angle. I have connected controller to Kflop step dir channel. Each 1/100 sec controller counts steps, calculates commanded velocity and transfer it to voltage applied to motor drive. Commanded velocity is proportional to output voltage. I had to use some math approximation cause of 8 bit controller, but velocity to voltage plot is almost linear with 2-3 % error, and little S-curve behavior.
Spindle sensor is 1000ppr optical encoder, max speed is 2000 rpm, so max velocity is 133 333 pps.
First of all if motor is not loaded I get max RPM at ~165 Vrms, also i have noticed that applied voltage is not directly proportional to RMP, actually not directly at all :) Also at low speeds spindle can be just stopped by hand (30 RPM).
I have to close the loop to operate at CCS and for threading.
So the questions is:
Can this setup operate in closed loop mode using KFLOP step dir chanel closed loop PID and filters? Or i should make come C program to drive my controller. Also is selected velocity control method is ok or I should change my controller software to be driving from PWM or something ?
Thx. in advance
B.R. Danchik